how to fix out of video memory trying to allocate a texture